package com.smedi.ismedi.inmail.api.dto.request.appVersion;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.*;

import javax.validation.constraints.NotNull;
import javax.validation.constraints.Pattern;
import javax.validation.constraints.Size;
import java.io.Serializable;

/**
 * @className: AppVersionPageRequest
 * @Description: TODO
 * @version: v1.0.0
 * @author: wzx
 * @date: 2023/8/30 13:58
 */

@Data
@Builder
@AllArgsConstructor
@NoArgsConstructor
@EqualsAndHashCode(callSuper = false)
@ApiModel(value = "App版本管理 分页 请求")
public class AppVersionPageRequest implements Serializable {

    /**
     * 分页行数
     */
    @NotNull
    @ApiModelProperty(value = "分页行数", example = "10")
    private long size;

    /**
     * 当前页数
     */
    @NotNull
    @ApiModelProperty(value = "当前页数", example = "1")
    private long current;

    /**
     * 排序字段
     */
    @ApiModelProperty(value = "排序字段" , example = "appVersion")
    private String orderBy;

    /**
     * 是否升序
     */
    @ApiModelProperty(value = "是否升序", example = "asc/desc")
    private String asc;

    /**
     * 版本号
    * */
    @ApiModelProperty(value = "版本号")
    @Pattern(regexp = "^$|^\\d{1,3}\\.\\d{1,3}\\.\\d{1,3}$", message = "版本号搜素格式不正确，应例如1.0.1！")
    private String appVersion;

    @ApiModelProperty(value = "更新方式", required = true)
    private String method;


}